<template>
  <Page
  :total="total"
  show-sizer
  :page-size-opts="pageswitch"
  @on-change ="switchPage"
  @on-page-size-change ="switchSize"
   />
</template>
<script>
export default {
  name: 'page-part',
  data () {
    return {
      pageswitch: [2, 3]
    };
  },
  props: {
    total: {
      required: true
    }
  },
  methods: {
    switchPage (currentpage) {
      this.$emit('getCurrentPage', currentpage);
    },
    switchSize (size) {
      this.$emit('getSize', size);
    }
  }
};
</script>
<style lang="less" scoped></style>
